/**
 * \file task/elf.c
 * \author Davide Gessa
 * \date 15-02-10
 */
#include <task/message.h>
#include <task/task.h>
#include <task/elf.h>
#include <video.h>
#include <debug.h>


/**
 * Check if the data is elf data
 * 
 * \return 1 if data is an elf
 */
uint32_t elf_check(char *buf)
{
	elf_header_t *header = (elf_header_t *) buf;
		
	if( (*(header->ident+1) == 'E') &&
		(*(header->ident+2) == 'L') &&
		(*(header->ident+3) == 'F') &&
		(*(header->ident) == 0x7f))
		return 1;
	
	return 0;		
}
